<?php
/**
 * 首页
 */
define('o', 0); //声明可以访问

// 载入初始化且必须在任何输出之前包括HTML标签
require_once('./include/initialize.php');

include(ROOT . '//model//select//index.php');


//$test = new XML('default');
//print_r($test->get_val('select','index'));

/*
$test = new Mysqlite(ROOT . "/data/main.db");
$temp = $test->query_many('xxx_tab', array('id', 'name', 'val'), ' where 1=1');
//$test->query_once('xxx_tab', array('id', 'name', 'val'), ' where 1=1');
//$test->insert('xxx_tab', array('name' => '你好', 'val' => '谢谢'));
$test->close();
//print_r($test->idlast());
$test1 = new templet(ROOT . '//templet//default//select//');
$test1 -> set_file('index', 'index_default.html');
$test1 -> set_list('index', 'id','list', $temp);
$test1 -> set_list('index', 'id','list1', $temp);
$test1 -> set_list('index', 'id','list2', $temp);
$test1 -> set_list('index', 'id','list3', $temp);
$test1 -> set_val('index', 'tit_le', '新网页');
$test1 -> parse('index');
*/
//print_r($temp);


//print_r($temp1);

// model::ini();
// phpinfo();
// $mysql = new Mysql();
// $mysql->connect();
// $mysql->select_db('test');
// print_r($mysql->query_many('abcd',array('a','b','c','d'),' where 1=1'));
// print_r($mysql->insert('abcd',array('a'=>8,'b'=>7,'c'=>7,'d'=>7)));
// print_r($mysql->update('abcd',array('a'=>11,'b'=>10,'c'=>11,'d'=>12),'a=\'10\''));
// print_r($mysql->delete_data('abcd','a>\'5\''));
// print_r($_GET);
// $db = new model();
// print_r($db);
// xml::test();
/**
 * $temp = array(array(array('baidu' => 'ns1'), array('google' => 'us1')), array(array('baidu' => 'ns2'), array('google' => 'us2')), array(array('baidu' => 'ns3'), array('google' => 'us3')), array(array('baidu' => 'ns4'), array('google' => 'us4')),array(array('baidu' => 'ns5'), array('google' => 'us5')),array(array('baidu' => 'ns6'), array('google' => 'us6')),array(array('baidu' => 'ns7'), array('google' => 'us7')),array(array('baidu' => 'ns8'), array('google' => 'us8')),array(array('baidu' => 'ns9'), array('google' => 'us9')),array(array('baidu' => 'ns10'), array('google' => 'us10')),array(array('baidu' => 'ns11'), array('google' => 'us11')),array(array('baidu' => 'ns12'), array('google' => 'us12')));
 * 
 * $temp1 = array(array(array('baidu' => 'ns31'), array('google' => 'u3s3')), array(array('baidu' => 'n3s4'), array('google' => 'u3s2')), array(array('baidu' => 'ns33'), array('google' => 'us3')), array(array('baidu' => 'ns4'), array('google' => 'us4')),array(array('baidu' => 'ns5'), array('google' => 'us5')),array(array('baidu' => 'ns6'), array('google' => 'us6')),array(array('baidu' => 'ns7'), array('google' => 'us7')),array(array('baidu' => 'ns8'), array('google' => 'us8')),array(array('baidu' => 'ns9'), array('google' => 'us9')),array(array('baidu' => 'ns10'), array('google' => 'us10')),array(array('baidu' => 'ns11'), array('google' => 'us11')),array(array('baidu' => 'ns12'), array('google' => 'us12')));
 * 
 * $test = new templet(ROOT . '//templet//default//select//');
 * $test -> set_file('index', 'index_default.html');
 * $test -> set_val('index', 'title', '新网页');
 * $test -> set_list('index', 'id','list', $temp1);
 * $test -> set_list('index','id', 'list2', $temp);
 * $test -> parse('index');
 */
/**
 * 动态读取设置配置文件
config :: create() -> dbserver = array('uip' => '192.168.0.1');
 * echo config :: create() -> dbserver['uip'];
 */
?>